/*
 * TITLE:RequestToServerTable
 * AUTHOR:Manori Thakur
 * PURPOSE: Sends a request to game server to verify credentials for the player trying to log in
 */
package clientrequest;

import java.util.Vector;

public class RequestLogin extends RequestToServer {
    private String version, username, password;

    @Override
    public void send(short requestCode, Vector args) {
        version = args.get(0).toString();
        username = args.get(1).toString();
        password = args.get(2).toString();
        short sizeofrequest =(short)(4+4*(version.length()+username.length()+password.length()));
        super.writeShort(sizeofrequest);
        super.writeShort(requestCode);
        super.writeString(version);
        super.writeString(username);
        super.writeString(password);
    }
}
